<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .box1 {
            /* 隐藏：彻底放弃了位置 */
            /* display: none; */
            width: 200px;
            height: 200px;
            background-color: orange;
        }
        
        .box2 {
            /* 隐藏：原位置保留 */
            visibility: hidden;
            width: 200px;
            height: 200px;
            background-color: pink;
            margin: 10px 0;
        }
        
        .box3 {
            width: 200px;
            height: 200px;
            background-color: skyblue;
        }
    </style>
</head>

<body>
    <div class="box1"></div>
    <div class="box2"></div>
    <div class="box3"></div>
</body>

</html>